/*
 * util.h
 *
 *  Created on: 2009-7-29
 *      Author: wyb
 */

#ifndef UTIL_H_
#define UTIL_H_

#include <stdio.h>
#include <stdlib.h>

#define PI 3.14159265358979323846

struct complex {
	double real;
	double imag;
};

struct double_array {
	int N;
	double *data;
};

struct int_array {
	int N;
	int *data;
};

void output_double_array(struct double_array *value, char *str);

void file_double_array(struct double_array *value, char *str);

struct double_array *merge_double_array(struct double_array *a1,
		struct double_array *a2);

#endif /* UTIL_H_ */
